//jsonp.js
export function JSONToGet(url) {
	return new Promise(function(resolve, reject) {
		window.handleResponse = function(data) {
		    resolve(data)
		}
		url+='&key=NCDBZ-XUYL3-7ND3Z-3FAZI-TFEU5-IXBKM&output=jsonp&callback=handleResponse'
		var script = document.createElement('script');
		script.src = url;
		document.body.appendChild(script);
	})
}